package com.web.app.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;

/**
 * <p>
 * 讨论表
 * </p>
 *
 * @author xxx
 * @since 2022-09-20
 */
@ApiModel(value = "Discuss对象", description = "讨论表")
public class MyDiscuss implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("讨论id")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty("关联班级id")
    private Integer relationClassId;

    @ApiModelProperty("关联学生id")
    private Integer relationStudentId;

    @ApiModelProperty("讨论内容")
    private String content;

    private String userAvatar;

    private String userNick;

    @ApiModelProperty("创建时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd hh:mm:ss")
    private Date createTime;

    private List<MyDiscussComment> comments;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getRelationClassId() {
        return relationClassId;
    }

    public void setRelationClassId(Integer relationClassId) {
        this.relationClassId = relationClassId;
    }

    public Integer getRelationStudentId() {
        return relationStudentId;
    }

    public void setRelationStudentId(Integer relationStudentId) {
        this.relationStudentId = relationStudentId;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getUserAvatar() {
        return userAvatar;
    }

    public void setUserAvatar(String userAvatar) {
        this.userAvatar = userAvatar;
    }

    public String getUserNick() {
        return userNick;
    }

    public void setUserNick(String userNick) {
        this.userNick = userNick;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public List<MyDiscussComment> getComments() {
        return comments;
    }

    public void setComments(List<MyDiscussComment> comments) {
        this.comments = comments;
    }

    @Override
    public String toString() {
        return "MyDiscuss{" +
                "id=" + id +
                ", relationClassId=" + relationClassId +
                ", relationStudentId=" + relationStudentId +
                ", content='" + content + '\'' +
                ", userAvatar='" + userAvatar + '\'' +
                ", userNick='" + userNick + '\'' +
                ", createTime=" + createTime +
                ", comments=" + comments +
                '}';
    }
}
